package com.example.selfcontrol.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data;

import java.util.Date;

@Data
public class Message {

    @TableId(type = IdType.AUTO)
    private Long id;

    private int isRead ;
    private int isDelete ;

    private Long userId ;

    private Long notifyId ;

    private Date createTime ;

    private String content ;

    public Message(Long userId, Long notifyId, String content) {
        this.userId = userId;
        this.notifyId = notifyId;
        this.content = content;

        this.isDelete = 0 ;
        this.isRead = 0 ;
        this.createTime = new Date() ;
    }
}
